//ISBN号码
import java.util.Scanner;

注意类名必须为 Main, 不要有任何 package xxx 信息
public class Main {
   public static void main(String[] args) {
       Scanner in = new Scanner(System.in);
       char[] arr = in.next().toCharArray();
       int sum = 0;
       int j = 1;
       for (int i = 0; i  arr.length-1; i++) {
           if (arr[i] == '-') {
               continue;
           }
           sum += (arr[i]-'0')  (j++);
       }
       sum %= 11;
       if (sum == arr[arr.length-1]-'0'  (sum == 10 && arr[arr.length-1] == 'X')) {
           System.out.println(Right);
       } else {
           for (int i = 0; i  arr.length-1; i++) {
               System.out.print(arr[i]);
           }
           char a = (char)('0'+sum);
           if (sum == 10) {
               a = 'X';
           }
           System.out.println(a);
       }
   }
}